package com.wenx.v3system.modular.platform.domain.maps;

import com.wenx.v3system.modular.platform.domain.dto.PlatformUserDto;
import com.wenx.v3system.modular.platform.domain.po.PlatformUser;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;

/**
 * 平台用户映射类
 * 
 * @author wenx
 */
@Mapper(componentModel = "spring")
public interface PlatformUserMap {

    PlatformUserMap INSTANCE = Mappers.getMapper(PlatformUserMap.class);

    /**
     * DTO转PO
     */
    PlatformUser toPo(PlatformUserDto dto);

    /**
     * PO转DTO
     */
    PlatformUserDto toDto(PlatformUser po);

    /**
     * DTO列表转PO列表
     */
    List<PlatformUser> toPoList(List<PlatformUserDto> dtoList);

    /**
     * PO列表转DTO列表
     */
    List<PlatformUserDto> toDtoList(List<PlatformUser> poList);
} 